package com.atguigu.springcloud.feign;

import com.atguigu.springcloud.entities.CommonResult;
import com.atguigu.springcloud.entities.Payment;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @Author: cheng song
 * @Description:
 * @Date: Created in 22:47 2021/9/4
 * @ModifiedBy:
 */

@Component
@FeignClient(value = "cloud-provider-service")
public interface PaymentFeignService {

    @GetMapping("/payment/get/{id}")
    public CommonResult selectPaymentById(@PathVariable("id") Long id);

    @GetMapping("/payment/feign/timeout")
    public CommonResult timeout();
}
